{include file="public/header" select="0" /}

<body>
<div class="title bgc">
    <i class="layui-icon layui-icon-left" onclick="goBack()"></i>
    绑定{$title}
</div>
<form action="{:url('user/method_save',['type'=>$type])}" method="post" class="form layui-form">
    <input type="hidden" name="go_back" value="{$Request.param.go_back}"/>
    <ul class="set-form bgc">
        {if $type == 'wechat' || $type == 'alipay'}
        <li class="wechat">
            <span>真实姓名</span>
            <label><input type="text" name="name" value="<?php echo $user[$type . '_name']?>" placeholder="请填写真实姓名"></label>
        </li>
        <li class="wechat right_parent">
            <span>{$title}收款码</span>
            <div class="right_div" id="uploads_image">
                <img class="right_img" src="<?php echo $user[$type . '_image'];?>"
                     onerror="this.src='/static/index/img/upload_img.png'"  alt="" id="image_show">
                <input type="hidden" name="image" id="images_value" value="<?php echo $user[$type . '_image'];?>"/>
            </div>
        </li>
        {else}
        <li class="bank">
            <span>银行名称</span>
            <div>
                <select name="bank_name" lay-verify="required" lay-reqtext="请选择银行" lay-verType="tips">
                    <option value="">请选择</option>
                    {foreach name="bank_list" item="vo" }
                    <option value="{$vo}" {if $user.bank_name == $vo}selected{/if} >{$vo}</option>
                    {/foreach}
                </select>
            </div>
        </li>
        <li class="bank">
            <span>开户行</span>
            <label><input type="text" name="bank_open" value="{$user.bank_open}" lay-verify="required"
                          lay-reqtext="请填写开户行" lay-verType="tips" placeholder="请填写开户行"></label>
        </li>
        <li class="bank">
            <span>银行户名</span>
            <label><input type="text" name="bank_account_name" value="{$user.bank_account_name}" lay-verify="required"
                          lay-reqtext="请填写银行户名" lay-verType="tips" placeholder="请填写银行户名"></label>
        </li>
        <li class="bank">
            <span>银行账号</span>
            <label><input type="text" name="bank_number"  value="{$user.bank_number}" lay-verify="required"
                          lay-reqtext="请填写银行账号" lay-verType="tips" placeholder="请填写银行账号"></label>
        </li>
        {/if}
    </ul>
    <div class="pay-btn"  lay-submit lay-filter="save" formObj=".form"><a>保存</a></div>
</form>
</body>
{include file="public/footer" select="0" /}